package com.ruoyi.web.nosecurity;

import com.ruoyi.web.controller.common.MinioController;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

@RestController
@RequestMapping("/nosecurity/file")
public class Minio2Controller {
    @Resource
    private MinioController minioController;

    /**
     * 下载文件
     */
    @GetMapping("/download")
    public void download(String saveFileName, HttpServletResponse response, HttpServletRequest request) throws Exception {
        minioController.download(saveFileName, response, request);
    }
}
